%%%-------------------------------------------------------------------
%%% File        : mailer.hrl
%%% Author      : Fyodor Ustinov <ufm@ufm.su>
%%% Description : MailEr Project
%%%             : Global definitions
%%%
%%% Created     : 24 Aug 2009 by Fyodor Ustinov <ufm@ufm.su>
%%%-------------------------------------------------------------------

-include_lib("kernel/include/inet.hrl").

-define(QUEUETIMEOUT,300000).             % Yes! 5 minuts.
-define(STORAGETIMEOUT,300000).             % Yes! 5 minuts.
-define(INBOUND, inbound).                % Inbound queue name

-record(user, {dname = {},                      % User name
	       node  = 'noname@nohost',         % Home node
	       id = ""                          % Internal ID
	      }).

-record(user_info, {id = "",                    % Internal user ID
		    dname = {},                 % ?
		    fname = "",                 % Full user name
		    password = "",              % User password
		    node = 'noname@nodomain',   % Home node name
		    last_login = 0,             % Last access time
		    mbox_size  = 0,             % Size of mailbox
		    max_mbox_size = 0,          % Max mailbox size
		    config = [],                % Configurations
		    pop3_config = [],           % Field for POP3 configuration
		    imap_config = [],           % Field for IMAP configuration
		    smtp_config = []            % Field for SMTP configuration
		   }).
